home *** CD-ROM | disk | FTP | other *** search
/ AmigActive 2 / AACD 2.iso / AACD / Magazine / GraphicsCards / StormMesa / src / teximage.h < prev    next >
C/C++ Source or Header  |  1999-02-04  |  7KB  |  188 lines

  1. /* $Id: teximage.h,v 3.0 1998/01/31 21:04:38 brianp Exp $ */
  2.  
  3. /*
  4.  * Mesa 3-D graphics library
  5.  * Version:  3.0
  6.  * Copyright (C) 1995-1998  Brian Paul
  7.  *
  8.  * This library is free software; you can redistribute it and/or
  9.  * modify it under the terms of the GNU Library General Public
  10.  * License as published by the Free Software Foundation; either
  11.  * version 2 of the License, or (at your option) any later version.
  12.  *
  13.  * This library is distributed in the hope that it will be useful,
  14.  * but WITHOUT ANY WARRANTY; without even the implied warranty of
  15.  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
  16.  * Library General Public License for more details.
  17.  *
  18.  * You should have received a copy of the GNU Library General Public
  19.  * License along with this library; if not, write to the Free
  20.  * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
  21.  */
  22.  
  23.  
  24. /*
  25.  * $Log: teximage.h,v $
  26.  * Revision 3.0  1998/01/31 21:04:38  brianp
  27.  * initial rev
  28.  *
  29.  */
  30.  
  31.  
  32. #ifndef TEXIMAGE_H
  33. #define TEXIMAGE_H
  34.  
  35.  
  36. #include "types.h"
  37.  
  38.  
  39. /*** Internal functions ***/
  40.  
  41.  
  42. extern struct gl_texture_image *gl_alloc_texture_image( void );
  43.  
  44.  
  45. extern void gl_free_texture_image( struct gl_texture_image *teximage );
  46.  
  47.  
  48. extern struct gl_image *
  49. gl_unpack_texsubimage( GLcontext *ctx, GLint width, GLint height,
  50.                        GLenum format, GLenum type, const GLvoid *pixels );
  51.  
  52.  
  53. extern struct gl_image *
  54. gl_unpack_texsubimage3D( GLcontext *ctx, GLint width, GLint height,GLint depth,
  55.                          GLenum format, GLenum type, const GLvoid *pixels );
  56.  
  57.  
  58. extern struct gl_texture_image *
  59. gl_unpack_texture( GLcontext *ctx,
  60.                    GLint dimensions,
  61.                    GLenum target,
  62.                    GLint level,
  63.                    GLint internalformat,
  64.                    GLsizei width, GLsizei height,
  65.                    GLint border,
  66.                    GLenum format, GLenum type,
  67.                    const GLvoid *pixels );
  68.  
  69. extern struct gl_texture_image *
  70. gl_unpack_texture3D( GLcontext *ctx,
  71.                      GLint dimensions,
  72.                      GLenum target,
  73.                      GLint level,
  74.                      GLint internalformat,
  75.                      GLsizei width, GLsizei height, GLsizei depth,
  76.                      GLint border,
  77.                      GLenum format, GLenum type,
  78.                      const GLvoid *pixels );
  79.  
  80.  
  81. extern void gl_tex_image_1D( GLcontext *ctx,
  82.                              GLenum target, GLint level, GLint internalformat,
  83.                              GLsizei width, GLint border, GLenum format,
  84.                              GLenum type, const GLvoid *pixels );
  85.  
  86.  
  87. extern void gl_tex_image_2D( GLcontext *ctx,
  88.                              GLenum target, GLint level, GLint internalformat,
  89.                              GLsizei width, GLint height, GLint border,
  90.                              GLenum format, GLenum type,
  91.                              const GLvoid *pixels );
  92.  
  93. extern void gl_tex_image_3D( GLcontext *ctx,
  94.                              GLenum target, GLint level, GLint internalformat,
  95.                              GLsizei width, GLint height, GLint depth,
  96.                              GLint border,
  97.                              GLenum format, GLenum type,
  98.                              const GLvoid *pixels );
  99.  
  100.  
  101. /*** API entry points ***/
  102.  
  103.  
  104. extern void gl_TexImage1D( GLcontext *ctx,
  105.                            GLenum target, GLint level, GLint internalformat,
  106.                            GLsizei width, GLint border, GLenum format,
  107.                            GLenum type, struct gl_image *teximage );
  108.  
  109.  
  110. extern void gl_TexImage2D( GLcontext *ctx,
  111.                            GLenum target, GLint level, GLint internalformat,
  112.                            GLsizei width, GLsizei height, GLint border,
  113.                            GLenum format, GLenum type,
  114.                            struct gl_image *teximage );
  115.  
  116.  
  117. extern void gl_TexImage3DEXT( GLcontext *ctx,
  118.                               GLenum target, GLint level, GLint internalformat,
  119.                               GLsizei width, GLsizei height, GLsizei depth,
  120.                               GLint border,
  121.                               GLenum format, GLenum type,
  122.                               struct gl_image *teximage );
  123.  
  124.  
  125. extern void gl_GetTexImage( GLcontext *ctx, GLenum target, GLint level,
  126.                             GLenum format, GLenum type, GLvoid *pixels );
  127.  
  128.  
  129.  
  130. extern void gl_TexSubImage1D( GLcontext *ctx,
  131.                               GLenum target, GLint level, GLint xoffset,
  132.                               GLsizei width, GLenum format, GLenum type,
  133.                               struct gl_image *image );
  134.  
  135.  
  136. extern void gl_TexSubImage2D( GLcontext *ctx,
  137.                               GLenum target, GLint level,
  138.                               GLint xoffset, GLint yoffset,
  139.                               GLsizei width, GLsizei height,
  140.                               GLenum format, GLenum type,
  141.                               struct gl_image *image );
  142.  
  143.  
  144. extern void gl_TexSubImage3DEXT( GLcontext *ctx,
  145.                                  GLenum target, GLint level,
  146.                                  GLint xoffset, GLint yoffset, GLint zoffset,
  147.                                  GLsizei width, GLsizei height, GLsizei depth,
  148.                                  GLenum format, GLenum type,
  149.                                  struct gl_image *image );
  150.  
  151.  
  152. extern void gl_CopyTexImage1D( GLcontext *ctx,
  153.                                GLenum target, GLint level,
  154.                                GLenum internalformat,
  155.                                GLint x, GLint y,
  156.                                GLsizei width, GLint border );
  157.  
  158.  
  159. extern void gl_CopyTexImage2D( GLcontext *ctx,
  160.                                GLenum target, GLint level,
  161.                                GLenum internalformat, GLint x, GLint y,
  162.                                GLsizei width, GLsizei height,
  163.                                GLint border );
  164.  
  165.  
  166. extern void gl_CopyTexSubImage1D( GLcontext *ctx,
  167.                                   GLenum target, GLint level,
  168.                                   GLint xoffset, GLint x, GLint y,
  169.                                   GLsizei width );
  170.  
  171.  
  172. extern void gl_CopyTexSubImage2D( GLcontext *ctx,
  173.                                   GLenum target, GLint level,
  174.                                   GLint xoffset, GLint yoffset,
  175.                                   GLint x, GLint y,
  176.                                   GLsizei width, GLsizei height );
  177.  
  178.  
  179. extern void gl_CopyTexSubImage3DEXT( GLcontext *ctx,
  180.                                      GLenum target, GLint level,
  181.                                      GLint xoffset, GLint yoffset,
  182.                                      GLint zoffset,
  183.                                      GLint x, GLint y,
  184.                                      GLsizei width, GLsizei height );
  185.  
  186. #endif
  187.  
  188.